package com.ruoyi.system.api.service.shop;

import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.system.api.domain.SysFile;
import com.ruoyi.system.api.factory.RemoteFileFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.multipart.MultipartFile;

// 修改 contextId 和类名以避免冲突
@FeignClient(contextId = "remoteCfUserFileService", value = ServiceNameConstants.CFUSER_SERVICE, fallbackFactory = RemoteFileFallbackFactory.class)
public interface RemoteCfUserFileService {  // 改名以更好地反映其功能
    
    @PostMapping("upload")
    public R<SysFile> uploadFile(MultipartFile file) throws Exception;
} 